<?php

/**
 * Created by PhpStorm
 * User: 林振宇
 * Date: 2020/8/18
 * Time: 14:48
 */

namespace app\api\controller;

use app\api\service\CancelService;
use app\api\service\TokenService;

class Cancel extends Base
{
    private $user_info;

    public function __construct()
    {
        $this->user_info = (new TokenService())->checkToken();
    }

    //核销记录
    public function cancelList()
    {
        $data = (new CancelService())->cancelList();
        $this->success('success', $data);
    }

    //核销记录详情
    public function cancelDetailsList()
    {
        $data = (new CancelService())->cancelDetailsList($this->user_info['id']);
        $this->success('success', $data);
    }

}
